import { xsEntity } from './commentity';
import { Column, Entity, ManyToOne } from 'typeorm';
import { UserEntity } from './user';

/**
 * 描述
 */
@Entity()
export class UseraddressEntity extends xsEntity {
    @Column({ comment: 'name' })
    name: string;
    @ManyToOne(() => UserEntity, user => user.address)
    userId: UserEntity;
    @Column({ default: null, comment: '是否为默认地址' })
    isDefault: boolean;
    @Column({ default: null, comment: '详细地址' })
    address: string;
    @Column({ default: null, comment: '手机号码' })
    mobile: string;
    @Column({ default: null, comment: '城市Id' })
    cityId: number;
    @Column({ default: null, comment: '省份Id' })
    provinceId: number;
    @Column({ default: null, comment: '区域Id' })
    areaId: number;




    @Column({ default: null, comment: '城市' })
    city: string;
    @Column({ default: null, comment: '省份' })
    province: string;
    @Column({ default: null, comment: '区域', })
    area: string;
    @Column({ default: null, comment: '门牌号', })
    detail: string;
    @Column({ comment: '区域', default: null })
    longitude: string;
    @Column({ comment: '区域', default: null })
    latitude: string;

    @Column({ comment: '是否删除', default: false })
    isdelete: boolean;




}
